package com.ktgj.hotel.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ktgj.hotel.mapper.DicCommonFacilitiesMapper;
import com.ktgj.hotel.domain.DicCommonFacilities;
import com.ktgj.hotel.service.IDicCommonFacilitiesService;

/**
 * 【请填写功能名称】Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-12-09
 */
@Service
public class DicCommonFacilitiesServiceImpl implements IDicCommonFacilitiesService 
{
    @Autowired
    private DicCommonFacilitiesMapper dicCommonFacilitiesMapper;

    /**
     * 查询【请填写功能名称】
     * 
     * @param id 【请填写功能名称】ID
     * @return 【请填写功能名称】
     */
    @Override
    public DicCommonFacilities selectDicCommonFacilitiesById(Long id)
    {
        return dicCommonFacilitiesMapper.selectDicCommonFacilitiesById(id);
    }

    /**
     * 查询【请填写功能名称】列表
     * 
     * @param dicCommonFacilities 【请填写功能名称】
     * @return 【请填写功能名称】
     */
    @Override
    public List<DicCommonFacilities> selectDicCommonFacilitiesList(DicCommonFacilities dicCommonFacilities)
    {
        return dicCommonFacilitiesMapper.selectDicCommonFacilitiesList(dicCommonFacilities);
    }

    /**
     * 新增【请填写功能名称】
     * 
     * @param dicCommonFacilities 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int insertDicCommonFacilities(DicCommonFacilities dicCommonFacilities)
    {
        return dicCommonFacilitiesMapper.insertDicCommonFacilities(dicCommonFacilities);
    }

    /**
     * 修改【请填写功能名称】
     * 
     * @param dicCommonFacilities 【请填写功能名称】
     * @return 结果
     */
    @Override
    public int updateDicCommonFacilities(DicCommonFacilities dicCommonFacilities)
    {
        return dicCommonFacilitiesMapper.updateDicCommonFacilities(dicCommonFacilities);
    }

    /**
     * 批量删除【请填写功能名称】
     * 
     * @param ids 需要删除的【请填写功能名称】ID
     * @return 结果
     */
    @Override
    public int deleteDicCommonFacilitiesByIds(Long[] ids)
    {
        return dicCommonFacilitiesMapper.deleteDicCommonFacilitiesByIds(ids);
    }

    /**
     * 删除【请填写功能名称】信息
     * 
     * @param id 【请填写功能名称】ID
     * @return 结果
     */
    @Override
    public int deleteDicCommonFacilitiesById(Long id)
    {
        return dicCommonFacilitiesMapper.deleteDicCommonFacilitiesById(id);
    }

    /**
     * 查询酒店筛选条件“服务设施”
     * */
    @Override
    public List<DicCommonFacilities> conditionServiceFacilities() {
        List<DicCommonFacilities> dicCommonFacilities = dicCommonFacilitiesMapper.conditionServiceFacilities();
        if (dicCommonFacilities != null){
            return dicCommonFacilities;
        }
        else {
            return null;
        }
    }
}
